package Chapter02.Homework;

import java.util.Scanner;

public class Work3 {
    public static void main(String[] args) {
        Scanner input=new Scanner(System.in);
        System.out.println("请输入作业名：");
        String name=input.next();
        if(name.endsWith(".zip")||name.endsWith(".rar")){
            name=name.substring(0,name.length()-4);
            int n=0;
            for (int i=0;i<name.length();i++){
                n=name.charAt(i);
                if(!(19968<=n&&n<40869)){
                    System.out.println("名称不正确");
                    return;
                }
            }
        }
        System.out.println("名称正确");
    }
}
